// sonet/textui/manager/Save.java
package sonet.textui.manager;
import static ist.po.ui.Dialog.IO;
import ist.po.ui.Command;
import ist.po.ui.DialogException;
import java.io.*;
import sonet.*;
import sonet.textui.*;


public class Save extends Command<BrowsingState> {
	public Save(BrowsingState state) {
		super(false, MenuEntry.SAVE, state);
	}
	/**
	 * @see ist.po.ui.Command#execute()
	 */	 

	@Override
	public final void execute()  throws DialogException, IOException {
		String file = IO.readString( Message.newSaveAs());
		
		Operations.saveSocialNetwork(_receiver.sonet,file);
	}
}
